package cn.jingzhuan.element.demo.view.epoxy.models

import android.view.View
import android.view.ViewGroup
import cn.jingzhuan.element.element.R
import cn.jingzhuan.element.element.databinding.ViewModuleTitleBinding
import com.airbnb.epoxy.DataBindingEpoxyModel
import com.airbnb.epoxy.EpoxyModelClass

@EpoxyModelClass(layout = R.layout.view_module_title)
abstract class TitleModel : DataBindingEpoxyModel() {

    var title:String =""

    override fun buildView(parent: ViewGroup): View {
        var view = super.buildView(parent)
        var binding = view.tag as ViewModuleTitleBinding
        binding.title.text = title
        return  view
    }
}